home *** CD-ROM | disk | FTP | other *** search
- ' A simple custom control that implements a push buttom
-
- Imports System.ComponentModel
- Imports System.Web.UI
-
- <DefaultProperty("Text"), ToolboxData("<{0}:FirstControl runat=server></{0}:FirstControl>")> Public Class FirstControl
- Inherits System.Web.UI.WebControls.WebControl
-
- ' The Text property
-
- Dim _text As String
-
- <Bindable(True), Category("Appearance"), DefaultValue("")> _
- Property [Text]() As String
- Get
- Return _text
- End Get
-
- Set(ByVal Value As String)
- _text = Value
- End Set
- End Property
-
- ' We override the Render method to send the correct HTML text
- ' to the client
-
- Protected Overrides Sub Render(ByVal output As System.Web.UI.HtmlTextWriter)
- output.Write("<input type=""button"" Value=""" & [Text] & """>")
- End Sub
-
- End Class
-